In networking systems, routers and/or switches typically use lookup tables to facilitate or increase the speed of the forwarding of packets of information. Such tables can be implemented in hardware, for example, as content-addressable memory (CAM), which can include static random access memory (SRAM) type memory cells. Among the types of forwarding that can be accommodated in typical systems are Layer 2 (L2) and/or Layer 3 (L3) forwarding. L2 tables can include Media Access Control (MAC) address lookup and L3 tables can include Internet Protocol (IP) address lookup. Other example table types include IP MultiCast (MC), IP Next Hop Table (NHT), and IP Longest Prefix Match (LPM) tables. Internal (i.e., on-chip) tables can be used for the L2/L3 forwarding and these tables can, in many cases, be modified by hardware and/or software control.
For systems that support more than one type of lookup, a typical approach for table management is shown in FIG. 1A. FIG. 1A is a block diagram of a conventional L2/L3 lookup table arrangement used for both L2 and L3 type lookups. General reference character 100 indicates Router/Switch 102 includes L2 Controller 104 for control of L2 Table 108 as well as L3 Controller 106 for control of L3 Table 110. L2 Table 108 has an entry width of 72-bits and L3 Table 110 has an entry width of 45-bits. In this conventional approach, one table is always configured as L2 type and the other is always configured as L3 type.
Referring now to FIG. 1B, a block diagram of a conventional L2/L3 lookup table arrangement used for only L2 type lookups is shown and indicated by the general reference character 150. Like numbers are typically used herein to indicate the same or similar components as in the diagram of FIG. 1A. In FIG. 1B, L3 Controller 106 has switched control from “enable” to “disable” so that L3 Table 110 is not used for L2 type lookups. Thus, the table designated for L3 lookups goes unused, as indicated by the cross-hatching in FIG. 1B, in this conventional approach. This can represent a large portion of the die area that is not utilized. Accordingly, this approach is not cost effective.
Consequently, what is needed is a solution that can control and allocate internal lookup tables so that each table is substantially utilized for a variety of different product configurations.